import { createRouter, createWebHistory, useRouter } from "vue-router";
import { routes } from "@/router/routes";

const router = createRouter({
    history: createWebHistory(),
    routes,
});


/**
 * 如果想要获取当前的路径地址
 */
const getPathAddress = () => {
    const currentRoute = useRouter().currentRoute.value;
    return currentRoute.fullPath;
}

export default router; getPathAddress;

